Static Analysis of Atomicity for Algorithms Using Non-Blocking Synchronization∗
نویسندگان
چکیده
In concurrent programming, non-blocking synchronization is very efficient but difficult to design correctly. This paper presents a static analysis to show that code blocks using non-blocking synchronization are atomic, i.e., that every execution of the program is equivalent to one in which those code blocks execute without interruption by other threads. Our analysis determines commutativity of operations based primarily on how synchronization primitives (including locks, Load-Linked, Store-Conditional, and Compare-and-Swap) are used. A reduction theorem states that certain patterns of commutativity imply atomicity. Atomicity is itself an important correctness requirement for many concurrent programs. Furthermore, an atomic code block can be treated as a single transition during subsequent analysis of the program; this can greatly improve the efficiency of the subsequent analysis; for example, it can significantly reduce the time and space for model checking. We demonstrate the effectiveness of our approach on several concurrent non-blocking programs.
منابع مشابه
Static Analysis of Atomicity for Programs with Lock-Free Synchronization∗
In concurrent programming, lock-free synchronization is veryefficient but difficult to design correctly. This paper presentsa static analysis to show that code blocks are atomic, i.e.,that every execution of the program is equivalent to onein which those code blocks execute without interruption byother threads. Our analysis determines commutativity ofoperations based pri...
متن کاملLanguage-level Transactions for Modular Reliable Systems
The transaction model is a natural means to express atomicity, fault-tolerance, synchronization, and exception handling in reliable programs. A (lightweight, in-memory) transaction can be thought of as a sequence of program loads and stores which either commits or aborts. If a transaction commits, then all of the loads and stores appear to have run atomically with respect to other transactions....
متن کاملStatic Detection of Atomicity Violations in Object-Oriented Programs
Violations of atomicity are possible sources of errors in parallel programs. A violation occurs if the effect of a method execution depends on the execution of concurrent threads that operate on the same or overlapping parts of a shared data structure. All accesses to shared data are assumed to be ordered through synchronization, hence common techniques for data race and deadlock detection are ...
متن کاملLiveness-Preserving Atomicity Abstraction
Modern concurrent algorithms are usually encapsulated in libraries, and complex algorithms are often constructed using libraries of simpler ones. We present the first theorem that allows harnessing this structure to give compositional liveness proofs to concurrent algorithms and their clients. We show that, while proving a liveness property of a client using a concurrent library, we can soundly...
متن کاملRelative Performance of Preemption-Safe Locking and Non-Blocking Synchronization on Multiprogrammed Shared Memory Multiprocessors
Most multiprocessors are multiprogrammed to achieve acceptable response time. Unfortunately, inopportune preemption may significantly degrade the performance of synchronized parallel applications. To address this problem, researchers have developed two principal strategies for concurrent, atomic update of shared data structures: (1) preemption-safe locking and (2) non-blocking (lock-free) algor...
متن کاملذخیره در منابع من
با ذخیره ی این منبع در منابع من، دسترسی به آن را برای استفاده های بعدی آسان تر کنید
عنوان ژورنال:
دوره شماره
صفحات -
تاریخ انتشار 2007